//
//  MyValuesViewController.m
//  BGM
//
//  Created by liuqin on 2018/11/29.
//  Copyright © 2018年 com.alirtc.demo. All rights reserved.
//

#import "MyValuesViewController.h"
#import "Common.h"
@interface MyValuesViewController ()

@end

@implementation MyValuesViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view.
    self.titleLabel.text = @"靠谱值";
    self.titleLabel.hidden = NO;
    UIImageView *topImage = [[UIImageView alloc]initWithFrame:CGRectMake(0, 0, SCREENW, 120)];
    [topImage setImage:[UIImage imageNamed:@"myvaluestop"]];
    [self.view addSubview:topImage];
    
    [self.view insertSubview:topImage belowSubview:self.backBtn];
    [self.view addSubview:self.titleLabel];

    
    UIImageView *valueImage = [[UIImageView alloc]initWithFrame:CGRectMake(0, 0, SCREENW/3, SCREENW/3)];
    [valueImage setImage:[UIImage imageNamed:@"meValues"]];
    valueImage.center = CGPointMake(SCREENW/2, 120+SCREENW/3/2);
    [self.view addSubview:valueImage];
    
    UILabel *valueLabel = [[UILabel alloc]initWithFrame:CGRectMake(5,-10,valueImage.frame.size.width, valueImage.frame.size.height)];
//    valueLabel.backgroundColor = [UIColor redColor];
    valueLabel.text = self.valueStr;
    valueLabel.textColor = bgmmainColor;
    valueLabel.textAlignment = NSTextAlignmentCenter;
    valueLabel.font = [UIFont systemFontOfSize:37];
    [valueImage addSubview:valueLabel];
    
    float y = valueImage.center.y+valueImage.frame.size.height;
    UIView *bgView = [[UIView alloc]initWithFrame:CGRectMake(15, y, SCREENW-30, SCREENH-y-30)];
    bgView.backgroundColor = [UIColor whiteColor];
    bgView.layer.cornerRadius = 8;
    bgView.layer.masksToBounds = YES;
    bgView.layer.borderColor = bgmgrayColor.CGColor;
    bgView.layer.borderWidth = 0.3;
    [self.view addSubview:bgView];
    
    NSString *title1 = @"什么是靠谱值?";
    NSString *content1 = @"靠谱值是一个人靠谱适度的重要体现，它能一定程度上折射出人的美好内在特质，靠谱值的高低取决于平时对别人帮助的多少，是一种在帮助别人的过程中获得的荣誉加成。";
    
    NSString *title2 = @"获取方式";
    NSString *content2 = @"1、帮助转发他人的救助信息+5靠谱值。2、成功完成一次他人的帮忙信息+100靠谱值。";
    
    UILabel *label = [[UILabel alloc]initWithFrame:CGRectMake(0, 0, bgView.frame.size.width, 40)];
    label.text = [NSString stringWithFormat:@"%@",title1];
    label.textAlignment = NSTextAlignmentCenter;
    label.font = [UIFont systemFontOfSize:17];
    label.textColor = bgmmainColor;
    [bgView addSubview:label];
    
    
    
    
    UILabel *label1 = [[UILabel alloc]initWithFrame:CGRectMake(15, 40, bgView.frame.size.width-30,100)];
    label1.text = [NSString stringWithFormat:@"%@",content1];
    label1.numberOfLines = 0;
    label1.textColor = bgmgrayColor;
    [bgView addSubview:label1];
    [label1 sizeToFit];
    
    
    UILabel *label3 = [[UILabel alloc]initWithFrame:CGRectMake(0, 140, bgView.frame.size.width, 40)];
    label3.text = [NSString stringWithFormat:@"%@",title2];
    label3.textAlignment = NSTextAlignmentCenter;
    label3.font = [UIFont systemFontOfSize:17];
    label3.textColor = bgmmainColor;
    [bgView addSubview:label3];
    
    UILabel *label4 = [[UILabel alloc]initWithFrame:CGRectMake(15, 180, bgView.frame.size.width-30,100)];
    label4.text = [NSString stringWithFormat:@"%@",content2];
    label4.numberOfLines = 0;
    label4.textColor = bgmgrayColor;
    [bgView addSubview:label4];
    [label4 sizeToFit];
    
}




/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
